{foreach $titleSearch as $post}
<tr>
    <td>{$post->getDateCreated()->format('Y-m-d')}</td>
    <td><a href="/user/view/{$post->getAuthor()->getUsername()}" alt="{$post->getAuthor()}">{$post->getAuthor()}</a></td>
    <td><a href="/post/read/{$post->getId()}" alt="{$post->getTitle()}">{$post->getTitle()}</a></td>
    <td>{$post->getReadCount()}</td>
    <td>{sizeof($post->getComments())}</td>
</tr>
{/foreach}